package com.yj.lottery_system.service;

import com.yj.lottery_system.controller.param.DrawPrizeParam;
import com.yj.lottery_system.controller.param.WinningRecordsParam;
import com.yj.lottery_system.dao.dataObject.WinningRecodesDO;
import com.yj.lottery_system.service.dto.WinningRecordsDTO;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public interface IDrawPrizeService {
    /**
     * 异步抽奖接口
     * @param param
     */
    void drawPrize(DrawPrizeParam param);

    /**
     * 校验抽奖请求
     * @param param
     */
    Boolean checkDrawPrizeParam(DrawPrizeParam param);

    /**
     * 保存中奖者名单
     * @param param
     */
    List<WinningRecodesDO> saveWinnerRecodes(DrawPrizeParam param);

    /**
     * 根据活动id和奖品id 删除中奖记录
     * @param activityId
     * @param prizeId
     */
    void deleteRecords(Long activityId, Long prizeId);

    /**
     * 获取中奖记录
     * @param param
     * @return
     */
    List<WinningRecordsDTO> getRecords(WinningRecordsParam param);
}
